import request from '@/utils/request'

//展示列表
export function majorList(data) {
	return request({
		url: '/major/majormainDO/',
		method: 'get',
	})
}
//根据pid查找列表
export function majorListPid(data) {
	return request({
		url: '/major/majormainDO/list',
		method: 'get',
		params:data
	})
}
// 根据id查找
export function majorGet(data) {
	return request({
		url: '/major/majormainDO/' + data.id,
		method: 'get',
	})
}
// 添加路由
export function addMajor(data) {
	return request({
		url: '/major/majormainDO',
		method: 'post',
		data
	})
}
// 编辑路由
export function updateMajor(data) {
	return request({
		url: '/major/majormainDO',
		method: 'put',
		data
	})
}
// 删除路由
export function deleteMajor(data) {
	return request({
		url: '/major/majormainDO/' + data.id,
		method: 'delete',
	})
}